package com.caac.core.dm;

/**
 * <p>Title: </p>
 * <p>Description: </p>
 * <p>Copyright: Copyright caac 2006</p>
 * <p>Company: caac</p>
 * @author <a href="mailto:project@caac.com.cn">Project Group</a>
 * @version 1.0
 */

public abstract class Prop extends BaseDm {
    private String id;
    private String groupName;
    private String propName;
    private Integer priority;
    private String subName;
    private String username;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getGroupName() {
        return groupName;
    }

    public void setGroupName(String groupName) {
        this.groupName = groupName;
    }

    public String getPropName() {
        return propName;
    }

    public void setPropName(String propName) {
        this.propName = propName;
    }

    public Integer getPriority() {
        return priority;
    }

    public String getSubName() {
        return subName;
    }

    public String getUsername() {
        return username;
    }

    public void setPriority(Integer priority) {
        this.priority = priority;
    }

    public void setSubName(String subName) {
        this.subName = subName;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    protected int doHashCode() {
        return getHashCodeBuilder().append(groupName).append(propName).
                toHashCode();
    }

    protected boolean doEquals(Object object) {
        Prop other = (Prop) object;
        return getEqualsBuilder().append(groupName,
                                         other.groupName).append(propName,
                other.propName).isEquals();
    }

    public abstract String getLabel();

}
